<!doctype html>
<html>

	<head>
		<meta charset="UTF-8">
		<title></title>
		<meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no" />
		<link href="../css/mui.min.css" rel="stylesheet" />
		
	</head>

	<body>
		<!--<header class="mui-bar mui-bar-nav">
			<a class="mui-action-back mui-icon mui-icon-left-nav mui-pull-left"></a>
			<h1 class="mui-title">标题</h1>
		</header>-->
		<script src="../lib/mui.min.js"></script>
		<script type="text/javascript">
			mui.init()
			mui.plusReady(function() {
				 
				var str = localStorage.getItem('userinfo')
				var userid = JSON.parse(str).id
				var str = 'alipays://platformapi/startapp?appId=20000067&url=https://openauth.alipay.com/oauth2/publicAppAuthorize.htm?app_id=2018042002584290&scope=auth_zhima&redirect_uri=&state='+userid
//			var	str ='alipays://platformapi/startapp?appId=20000067&url=https%3a%2f%2fopenauth.alipay.com%2foauth2%2fpublicAppAuthorize.htm%3fapp_id%3d2018042002584290%26scope%3dauth_zhima%26redirect_uri%3dhttp%3a%2f%2fwww.happyhelphelp.com%2fapp%2falipay%2fzhima%26state%3d'+userid
				alert(str)
				location.href=str
//				
//				var self = plus.webview.currentWebview();
//				var baiduWV = plus.webview.create("alipays://platformapi/startapp?appId=20000067&url=https://openauth.alipay.com/oauth2/publicAppAuthorize.htm?app_id=2018042002584290&scope=auth_zhima&redirect_uri=http://www.happyhelphelp.com/app/alipay/zhima&state=", "baidu", {
//					
//					bottom: 0
//				});
////				baiduWV.appendJsFile("_www/js/insert.js"); 
//				self.append(baiduWV)
//				baiduWV.addEventListener('loaded',function(event){
//					console.log("监听事件========="+baiduWV.getURL())
//					var url = baiduWV.getURL().split('?')[0];
//					if(url == "https://www.baidu.com/"){
//						plus.webview.close(plus.webview.currentWebview())
//					}
//				})
//				
//				
			})
		</script>
	</body>

</html>